// var away = document.querySelector('.away')
// away.addEventListener('click', function() {
// 	// location.href = 'https://landlord.zhihuifangdong.net/#/login'
// 	window.open('https://landlord.zhihuifangdong.net/#/login')
// })
var app = document.querySelector('.btnapp')
var model = document.querySelector('.model')
app.addEventListener('click', function() {
	model.style.display = 'block'
})
window.onclick = function(e){
	if(e.target !== app){
		model.style.display = 'none'
	}
}
var content_img = document.querySelectorAll('.content_img')
var content_imgmove = document.querySelectorAll('.content_imgmove')
var father = document.querySelectorAll('.father')
for(let i =0 ; i<father.length;i++){
	father[i].addEventListener('mouseover', function(){
		content_img[i].style.display = 'block'
		content_imgmove[i].style.display = 'none'
	})
	father[i].addEventListener('mouseout',function(){
		content_img[i].style.display = 'none'
		content_imgmove[i].style.display = 'block'
	})
}
// tab页的切换
var left = document.querySelector('.left')
var lis = left.querySelectorAll('li')
var imgs = document.querySelectorAll('.img')
for(let i =0;i<lis.length;i++){
	lis[i].setAttribute('index', i);
	lis[i].onclick = function(){
		for(let i=0;i<lis.length;i++){
			lis[i].className = ''
		}
		this.className = 'current2'
		let index = this.getAttribute('index');
		for(let i=0;i<imgs.length;i++){
			imgs[i].style.display = 'none';
		}
		imgs[index].style.display = 'block'
	}
}
